package com.ktgj.pay.phoneSound;

import java.util.Date;

import com.ktgj.pay.utils.Toolkit;

public class Console {

	public static void WriteLine(String outstr) {
		System.out.println(outstr);
	}

	public static String ReadLine() {
		int ch;
        String r = "";
        boolean done = false;
        while (!done) {
            try {
                ch = System.in.read();
                if (ch < 0 || (char) ch == '\n') {
                    done = true;
                } else if ((char) ch != '\r') {
                    r = r + (char) ch;
                }
            } catch (java.io.IOException e) {
                done = true;
            }
        }
        return r;
	}

	public static void WriteLine(SimpleXml xml) {
		System.out.println(xml);
	}

	public static String GetSerialNo()
	{
		return Toolkit.HHmmss(new Date());
	}

	public static String GetMerchantOrderNo()
	{
		return Toolkit.yyyyMMddHHmmss(new Date());
	}

}
